package com.lg.shiro;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.lg.redis.simple.RedisClient;

import redis.clients.jedis.Jedis;
@Component
public class RedisContext {
    @Autowired
	private RedisClient redisClient;
	public  static volatile ThreadLocal<Jedis> jedisContext = new ThreadLocal<>();
	
	public static void set(Jedis jedis) {
		jedisContext.set(jedis);
	}
	
	public static Jedis get() {
		
		return jedisContext.get();
	}
}
